<?php
	require_once "weixin_info.php";
	require_once "config.php";
	$id = $_GET['id'];
	$deta_sql = $mysql->query('select * from dyspw_shop_detailed where id = '.$id);
	$deta = $deta_sql->fetch_all(MYSQLI_ASSOC);
	$bank_sql = $mysql->query('select * from dyspw_mem_bank where id = '.$deta[0]['bank_id']);
	$bank = $bank_sql->fetch_all(MYSQLI_ASSOC);
 ?>
<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0,viewport-fit=cover">
    <title>提现详情</title>
    <!-- 引入组件库 -->
    <link rel="stylesheet" href="./lib-Jin/vant-index.css">
    <script src="./lib-Jin/vue.min.js"></script>
    <script src="./lib-Jin/vant-index.js"></script>
    <link rel="stylesheet" href="./lib-Jin/all.css">
    <link rel="stylesheet" href="./css/mingxi.css">
</head>
<body>
    <div id="app">
        <div class="top">
            <div class="back" @click="back">
                <img src="./images/back1.png">
            </div>
            提现详情
        </div>
        <div class="tixian-info">
            <div style="font-size: .3rem;color: #000;"><?php echo $bank[0]['bank_name'] ?></div>
            <div style="font-size: .45rem;color: #000;margin: .4rem 0 .3rem;font-weight: bold;"><?php echo $deta[0]['cash_money'] ?></div>
            <div style="font-size: .3rem;color: #000;"><?php if($deta[0]['case_state'] == 1){echo '提现申请已通过，正在放款';}elseif($deta[0]['case_state'] == 2){echo '提现申请驳回';}else{ echo '交易处理中';} ?></div>
        </div>
        <div class="goods-list1">
            <div class="detail-info-list1">
                <div style="font-size: .26rem;color: #595757;">提现到</div>
                <div style="font-size: .24rem;color: #000;"><?php echo $bank[0]['bank_num'] ?></div>
            </div>
            <div class="detail-info-list1">
                <div style="font-size: .26rem;color: #595757;">开户行地址</div>
                <div style="font-size: .24rem;color: #000;"><?php echo $bank[0]['bank_add'] ?></div>
            </div>
            <div class="detail-info-list1">
                <div style="font-size: .26rem;color: #595757;">处理进度</div>
                <div class="steps">
                    <div style="display: flex;align-items: center;">
                        <img src="./images/tixian1.png" style="width: .3rem;height: .3rem;margin-right: .3rem;">
                        <span style="font-size: .3rem;color: #3f5dd7;font-weight: bold;margin-right: .8rem;">提现时间</span>
                        <div style="font-size: .26rem;color: #595757;"><?php echo date('m-d H:i', $deta[0]['case_time']); ?></div>
                    </div>
					<?php if($deta[0]['case_state'] == 1){ ?>
						<div style="display: flex;align-items: center;">
							<img src="./images/tixian1.png" style="width: .3rem;height: .3rem;margin-right: .3rem;">
							<span style="font-size: .3rem;color: #3f5dd7;font-weight: bold;margin-right: .8rem;">申请成功</span>
							<div style="font-size: .26rem;color: #595757;"><?php echo date('m-d H:i', $deta[0]['handle_time']); ?></div>
						</div>
					<?php }elseif ($deta[0]['case_state'] == 2) { ?>
						<div style="display: flex;align-items: center;">
							<img src="./images/tixian1.png" style="width: .3rem;height: .3rem;margin-right: .3rem;">
							<span style="font-size: .3rem;color: #3f5dd7;font-weight: bold;margin-right: .8rem;">申请驳回</span>
							<div style="font-size: .26rem;color: #595757;"><?php echo date('m-d H:i', $deta[0]['handle_time']); ?></div>
						</div>
					<?php }else{ ?>
						<div style="display: flex;align-items: center;">
							<img src="./images/tixian2.png" style="width: .3rem;height: .3rem;margin-right: .3rem;">
							<span style="font-size: .3rem;color: #3f5dd7;font-weight: bold;margin-right: .8rem;">正在处理</span>
							<!-- <div style="font-size: .26rem;color: #595757;">03-27 13:44</div> -->
						</div>
					<?php } ?>
                </div>
            </div>
            <div class="detail-info-list1">
                <div style="font-size: .26rem;color: #595757;">提现时间</div>
                <div style="font-size: .24rem;color: #000;"><?php echo date('Y-m-d H:i:s', $deta[0]['handle_time']); ?></div>
            </div>
            <!-- <div class="detail-info-list1">
                <div style="font-size: .26rem;color: #595757;">订单号</div>
                <div style="font-size: .24rem;color: #000;">12345678978974653215463</div>
            </div> -->
        </div>
    </div>
</body>
</html>
<script>
    new Vue({
        el:"#app",
        data:{
            date: '',
            show: true,
            list: [1,1,1,1,1,1]
        },
        methods: {
            back(){
                window.history.back()
            },
            showRiLi(){
                console.log(1)
                this.show = true
            },
            formatDate(date) {
                return `${date.getMonth() + 1}/${date.getDate()}`;
            },
            onConfirm(date) {
                this.show = false;
                this.date = this.formatDate(date);
            },
        },
        mounted () {
            // console.log(this.show)
        }
    })

    Vue.use(
        vant.Calendar
    );
</script>
<script>
    (function (doc, win) {
    var docEl = doc.documentElement,
        resizeEvt = 'orientationchange' in window ? 'orientationchange' : 'resize',
        recalc = function () {
        var clientWidth = docEl.clientWidth
        if (!clientWidth) return
        if (clientWidth >= 750) {
            docEl.style.fontSize = '100px'
        } else {
            docEl.style.fontSize = 100 * (clientWidth / 750) + 'px'
        }
        }
    if (!doc.addEventListener) return
    win.addEventListener(resizeEvt, recalc, false)
    doc.addEventListener('DOMContentLoaded', recalc, false)
    })(document, window)
</script>
